package com.gof.example.builder;

/**
 * Created with IntelliJ IDEA.
 * Created by zhiyuan on 2018/5/4 09:35.
 * haiming.fei@tongdun.cn
 */
public abstract class DisplayBuilder {

    protected Model model;

    public DisplayBuilder(Model m) {
        this.model = m;
    }

    public DisplayBuilder() {
    }

    abstract void showMenu();

    abstract void showPlayList();

    abstract void showMainWindow();

    abstract void showControlBar();

    abstract void showFavouriteList();

    public void setModel(Model model) {
        this.model = model;
    }

    public Model build() {
        this.showMenu();
        this.showPlayList();
        this.showMainWindow();
        this.showControlBar();
        this.showFavouriteList();
        return model;
    }
}
